package com.kele.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletResponse;

/**
 * @Version 2019
 * @Author:kele
 * @Date:2021/5/28
 * @Content:
 * @Description：
 */
@Controller
@RequestMapping("/rest")
public class RESTController {

    @RequestMapping("/get")
    @ResponseBody
    public String find(){
        return "get 请求。。。。";
    }
    @PostMapping("/post")
    @ResponseBody
    public String add(){
        return "post 请求。。。。";
    }
    @PutMapping("/update")
    @ResponseBody
    public String update(HttpServletResponse response){
        response.setCharacterEncoding("utf-8");
        return "put 请求。。。。";
    }
    @DeleteMapping("/delete")
    @ResponseBody
    public String delete(){
        return "delete请求。。。。";
    }


}
